package br.univas.vperiod.jowey.entities;

import java.io.Serializable;
import java.util.Set;

import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.OneToMany;
import javax.persistence.Table;

@Entity
@Table(name="activity")
public class Activity implements Serializable {
	
	/**
	 * 
	 */
	private static final long serialVersionUID = 4859717190841284981L;

	@Id
	@GeneratedValue(strategy=GenerationType.IDENTITY)
	private long idActivity;
	
	private String activityDescription;
	
	@OneToMany(mappedBy="activity",targetEntity=PlayerJob.class,fetch=FetchType.LAZY)
	private Set<PlayerJob> playerJobs;
	
	

	public long getIdActivity() {
		return idActivity;
	}

	public void setIdActivity(long idActivity) {
		this.idActivity = idActivity;
	}

	public String getActivityDescription() {
		return activityDescription;
	}

	public void setActivityDescription(String activityDescription) {
		this.activityDescription = activityDescription;
	}

	public Set<PlayerJob> getPlayerJobs() {
		return playerJobs;
	}

	public void setPlayerJobs(Set<PlayerJob> playerJobs) {
		this.playerJobs = playerJobs;
	}
}